﻿using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Text.Json.Serialization;
namespace BPM.Web.Shared.Data;

public partial class AddAppInput : BaseVM
{
    /// <summary>
    /// 主键Id
    /// </summary>
    [DisplayName("业务号")]
    [Required(ErrorMessage = "业务号不能为空")]
    [JsonPropertyName("id")]
    public long Id { get; set; }

    /// <summary>
    /// 名称
    /// </summary>
    [DisplayName("名称")]
    [JsonPropertyName("name")]
    [Required(ErrorMessage = "名称不能为空")]
    public string? Name { get; set; }

    /// <summary>
    /// 编码
    /// </summary>
    [DisplayName("编码")]
    [JsonPropertyName("code")]
    [Required(ErrorMessage = "编码不能为空")]
    public string? Code { get; set; }

    /// <summary>
    /// 图标
    /// </summary>
    [DisplayName("图标")]
    [JsonPropertyName("icon")]
    [Required(ErrorMessage = "图标不能为空")]
    public string? Icon { get; set; }

    /// <summary>
    /// 是否默认激活（Y-是，N-否）,只能有一个系统默认激活
    /// <br/>用户登录后默认展示此系统菜单
    /// </summary>
    [DisplayName("是否默认激活")]
    [JsonPropertyName("active")]
    public string Active { get; set; } = "N";

    [DisplayName("状态")]
    [JsonPropertyName("status")]
    public CommonStatus Status { get; set; }

    /// <summary>
    /// 排序
    /// </summary>
    [DisplayName("排序")]
    [JsonPropertyName("sort")]
    public int Sort { get; set; }

}
